import axios from 'axios'
import { message } from 'antd'

const request = axios.create({
    baseURL: "http://localhost:3000",
    timeout: 4000
})

request.interceptors.response.use(res => {
    const { status , msg } = res.data
    status && message.info(msg)
    return res.data
})

export default request
